<!DOCTYPE html>
<html>

<head>

    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title></title>
    <meta name="keywords" content="">
    <meta name="description" content="">

    <link rel="shortcut icon" href="favicon.ico"> 
    <link href="__STATIC__/layout/css/bootstrap.min.css?v=3.3.6" rel="stylesheet">
    <link href="__STATIC__/layout/css/font-awesome.css?v=4.4.0" rel="stylesheet">
     <!-- jqgrid-->
    <link href="__STATIC__/layout/css/animate.css" rel="stylesheet">
    <link href="__STATIC__/layout/css/style.css?v=4.1.0" rel="stylesheet">
    <link href="__STATIC__/layout/css/plugins/sweetalert/sweetalert.css" rel="stylesheet">
    <link href="__STATIC__/layout/css/gyq.css" rel="stylesheet">
    <link rel="stylesheet" href="__STATIC__/layout/css/demo.css" type="text/css">
</head>

<body style="color:#333;padding:3px;">
    <!-- 标题 -->
    <div class="page-heade clearfix">
      <h2 class="clearfix text-center"><a class="col-md-6 title_color H_right H_active" id="Ap1" style="font-size: 16px">AP费用需反馈申请</a> <a class="col-md-6 title_color"  id="Ap2" style="color:#333;font-size: 16px" href="{:url('apRtRight')}">AP费用反馈报告</a></h2>
    </div>
    <!-- 标题 -->
    <div class="form-inline">
    <form action="#" method="post" id="form_check">
      <table class="row-margin-top tab-content table-bordered table text-center" border="1">
         <tr>
                <td><label for="" class="form-label">编号：</label><input type="text" class="form-control" name="no" value="{$data.no}"></td>
                <td><label for="">主题：</label><input type="text" class="form-control" name="title" value="{$data.title}"></td>
                <td><label for="">状态：</label>
                    <select name="state" id="state" class="form-control select" style="min-width: 100px;width: 100px">
                        <option value="0">请选择</option>
                        {volist name="states" id="sta"}
                        {if condition="$data.state eq $sta.id"}
                        <option value="{$sta.id}" selected>{$sta.title}</option>
                        {else/}
                        <option value="{$sta.id}">{$sta.title}</option>
                        {/if}
                        {/volist}
                    </select></td>
                <td>
                    <div class="form-group">
                        申请时间
                    </div>
                    <div class="form-group">
                        <input type="text" id="start" placeholder="开始日期" class="form-control layer-date "
                               style="min-width:100px;height: 22px;display: inline-block;" name="start" value="{$data.start}">
                    </div>
                    <div class="form-group">
                        至
                    </div>
                    <div class="form-group">
                        <input type="text" class="form-control layer-date" placeholder="结束日期"
                               style="min-width:100px;height: 22px;display: inline-block;" id="end" name="end" value="{$data.end}">
                    </div>
                </td>
                <td>
                    <button class="btn btn-info query" type="button" id="check">查询</button>
                    <button class="btn btn-info emptyIf" type="button" id="clear_check">清空查询条件</button>
                </td>
            </tr>
      </table>
    
      <table class="table table-striped row-margin-top table-bordered text-center bud_hei">
          <tr class="info text-center">
            <th class="text-center">NO.</th>
            <th class="text-center">类型</th>
            <th class="text-center">编号</th>
            <th class="text-center">主题</th>
            <th class="text-center">状态</th>
            <th class="text-center">申请人</th>
            <th class="text-center">申请时间</th>
            <th class="text-center">操作</th>
          </tr>
          {volist name="applys" id="vo"}
              <tr class="text-center">
                <td>{$i}</td>
                <td>常规促销{if condition="$vo.is_actived eq 0 "}取消{else/}{if condition="$vo.yuantag eq 1"}异动{else/}申请{/if}{/if}</td>
                <td><a href="javascript:;" onclick="xiangqing({$vo.id})">{$vo.no}</a></td>
                <td>
                    {if condition="$vo.tag eq 2"}
                   <span class="quxiao">
                   {elseif condition="$vo.tag eq 1"/}
                    <span class="is_yd">
                    {else/}
                    <span>
                   {/if}
                           {$vo.title}         
                     
                     
                      </span>  
                     
                        {if condition="$vo.tag eq 0"}
                            
                           
                             {if condition="$vo.is_shengxiao eq 1"}
                                <span class="glyphicon glyphicon-ok duigou" title="已生效" aria-hidden="true"></span>
                            {/if}
                             {if condition="$vo.is_fankui neq 0"}
                                <span class="glyphicon glyphicon-send fankui" title="已反馈" aria-hidden="true"></span>
                            {/if}
                             {if condition="$vo.is_hexiao neq 0"}
                                <span class="glyphicon glyphicon-yen fankui" style="color:gold;" title="已核销" aria-hidden="true"></span>
                            {/if}
                        {elseif condition="$vo.tag eq 1"}
                         <!--异动图标-->
                           <span class="glyphicon glyphicon-remove delCssY" style="color:blue;" title="已异动" aria-hidden="true"></span>
                        {elseif condition="$vo.tag eq 2"}
                         <!--删除图标-->
                           <span class="glyphicon glyphicon-remove delCssQ" title="已删除" aria-hidden="true"></span>
                        {/if}
                    
                    
                </td>
                <td>{$vo.zhuangtai}</td>
                <td>{$vo.cname}</td>
                <td>{$vo.created_on}</td>
                <td> <a class="feedback" aid="{$vo.id}">反馈</a></td>
            </tr>
            {/volist}
      </table>
</form>
    </div>
  <!-- 全局js -->
    <script src="__STATIC__/layout/js/jquery.min.js?v=2.1.4"></script>
    <script src="__STATIC__/layout/js/bootstrap.min.js?v=3.3.6"></script>
    <!-- <script src="js/plugins/metisMenu/jquery.metisMenu.js"></script> -->
    <script src="__STATIC__/layout/js/plugins/slimscroll/jquery.slimscroll.min.js"></script>
    <!--统计代码，可删除-->
    <script src="__STATIC__/layout/js/plugins/layer/laydate/laydate.js"></script>
    <script src="__STATIC__/layout/js/plugins/sweetalert/sweetalert.min.js"></script>
<script src="__STATIC__/layout/js/plugins/layer/layer.min.js"></script>
    <script>
      
        //日期范围限制
        var start = {
            elem: '#start',
            format: 'YYYY/MM/DD',
            min: laydate.now(), //设定最小日期为当前日期
            max: '2099-06-16 23:59:59', //最大日期
            istime: true,
            istoday: false,
            choose: function (datas) {
                end.min = datas; //开始日选好后，重置结束日的最小日期
                end.start = datas //将结束日的初始值设定为开始日
            }
        };
        var end = {
            elem: '#end',
            format: 'YYYY/MM/DD',
            min: laydate.now(),
            max: '2099-06-16 23:59:59',
            istime: true,
            istoday: false,
            choose: function (datas) {
                start.max = datas; //结束日选好后，重置开始日的最大日期
            }
        };
        laydate(start);
        laydate(end);
         //详情也
function xiangqing(aid){
     var index = layer.open({
                            type:2,
                            title:'常规促销申请',
                            area:['100%','100%'],
                            maxmin:true,
                            content:'{:url("apply_de")}?aid='+aid
                        })
}
   $(".feedback").click(function(){
         location.href="{:url('fankui')}?aid="+$(this).attr("aid")+"&rt=1";

    })
   //查询
        $("#check").click(function(){
              
              document.getElementById("form_check").submit();
        })
        $("#clear_check").click(function(){
            $("input[type='text']").val("");
            $("#state").val(0);
             document.getElementById("form_check").submit();
        })

    </script>
</body>

</html>
